/**
 * Created with IntelliJ IDEA.
 * User: ajhin
 * Date: 8/7/13
 * Time: 6:06 PM
 * To change this template use File | Settings | File Templates.
 */
package societyGames.codeAlong.model
{
import societyGames.xmlFragment.XMLFragment;

public class Term extends XMLFragment
{
  override protected function getDefaultXML():XML
  {
    return _defaultXML;
  }

  public function get name():String
  {
    return _xml.@name;
  }

  [Bindable]
  public function set name(value:String):void
  {
    _xml.@name = value;
  }

  public function get definition():String
  {
    return _xml.toString();
  }

  [Bindable]
  public function set definition(value:String):void
  {
    _xml.setChildren(value);
  }

  private const _defaultXML:XML =
          <term name="exception">An error caused by nonsensical code.</term>;
}
}
